feat: add make sbom / install-sbom / uninstall-sbom targets - #410
feat: add make sbom / install-sbom / uninstall-sbom targets#410MarkAtwood wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds SBOM generation and install/uninstall targets to the autotools build so wolfProvider can emit CycloneDX 1.6 and SPDX 2.3 artifacts (via wolfSSL’s gen-sbom script), plus configure-time discovery of required tooling.
Changes:
- Add
make sbom,make install-sbom, andmake uninstall-sbomtargets that stage-install the built artifacts and generate CycloneDX/SPDX outputs. - Add
AC_CHECK_PROGchecks forpython3andpyspdxtoolsinconfigure.ac.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| Makefile.am | Adds SBOM generation and install/uninstall targets and related variables. |
| configure.ac | Adds checks for python3 and pyspdxtools availability. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
a93e1f6 to
8db5499
Compare
aidangarske
left a comment
There was a problem hiding this comment.
🐺 Skoll Code Review
Overall recommendation: REQUEST_CHANGES
Findings: 2 total — 2 posted, 0 skipped
Posted findings
- [High] SBOM version lookup breaks clean out-of-tree builds and overrides Automake VERSION —
Makefile.am:60-71 - [Medium] pyspdxtools probe is never enforced by the sbom target —
configure.ac:30, Makefile.am:80-83
Review generated by Skoll.
|
Both Skoll findings are against code that isn't in this PR (verified against the current head):
The recipe was refactored into the shared |
Detailed verification — both Skoll findings are against code that isn't in this PRChecked two ways against the reviewed head Finding 1 — "VERSION grep at
|
aidangarske
left a comment
There was a problem hiding this comment.
🐺 Skoll Code Review
Overall recommendation: REQUEST_CHANGES
Findings: 2 total — 2 posted, 0 skipped
Posted findings
- [High] SBOM option capture omits configured compiler defines —
scripts/sbom.am:129-131 - [Low] SBOM workflow executes mutable external gen-sbom ref —
.github/workflows/sbom.yml:42-47
Review generated by Skoll.
dgarske
left a comment
There was a problem hiding this comment.
@sameehj or @MarkAtwood please see feedback #410 (review)
|
On the second finding (mutable gen-sbom ref in the workflow): pinned. The |
4109012 to
ecc3e2e
Compare
|
Retest this please Jenkins. @aidangarske , @dgarske it looks like the review comments got marked as resolved. Can you re-review? |
aidangarske
left a comment
There was a problem hiding this comment.
CI needs some work thanks
ecc3e2e to
4935f31
Compare
|
Addressed the 12 Aug review (#410 (review)):
A per-PR |
4b3fc71 to
0d54417
Compare
Add CycloneDX + SPDX SBOM targets (make sbom / install-sbom / uninstall-sbom) using the wolfGlass toolkit under tools/sbom/. wolfProvider records wolfSSL and OpenSSL as dependencies, pins SBOM_CONFIG_H at include/config.h, and runs the full stack job on nightly and the ci:sbom label. Do not assign SBOM_GEN or SBOM_VENDOR_DIR in Makefile.am: Automake -Werror treats a second assignment in the included fragment as fatal. Pass the raw OpenSSL version (including BUILD_METADATA) to gen-sbom. CPE 2.3 and PURL identifiers drop the +suffix; versionInfo keeps it. Co-authored-by: Mark Atwood <mark@wolfssl.com> Signed-off-by: Sameeh Jubran <sameeh@wolfssl.com>
e0f47ba to
fd6f10b
Compare
purl-spec requires pkg:github namespace and name to be lowercased. gen-sbom already emits pkg:github/wolfssl/wolfprovider@...; the CI assert still looked for wolfSSL and failed the identity step. Signed-off-by: Sameeh Jubran <sameeh@wolfssl.com>
| * ML-DSA (FIPS 204): ML-DSA-44, ML-DSA-65, ML-DSA-87 (signatures, pure mode with empty context per FIPS 204 sec 5.2) | ||
|
|
||
|
|
||
| ## SBOM / EU CRA Compliance |
There was a problem hiding this comment.
This is not the right spot for this documentation I would suggest creating a SBOM.md or better a chapter in the documentation repo for WP
aidangarske
left a comment
There was a problem hiding this comment.
Skoll Code Review
Scan type: review
Overall recommendation: COMMENT
Findings: 3 total — 1 posted, 2 skipped
1 finding(s) posted as inline comments (see file-level comments below)
Posted findings
- [Low] SBOM package name (wolfprovider) diverges from autoconf package (wolfprov) —
Makefile.am:63
Skipped findings
- [Info]
Redundant AC_SUBST calls after AC_PATH_PROG - [Info]
EXTRA_DIST of tools/sbom directory is not .gitignore-aware
Review generated by Skoll
| # next to the fragment, so `make sbom` does not need a wolfSSL source tree. | ||
| # Set WOLFSSL_DIR only when you want the SBOM to read the linked wolfSSL | ||
| # version from wolfssl/version.h. | ||
| SBOM_PKGNAME = wolfprovider |
There was a problem hiding this comment.
SBOM package name (wolfprovider) diverges from autoconf package (wolfprov)
SBOM_PKGNAME = wolfprovider but configure.ac:8 declares AC_INIT([wolfprov], [1.2.1]) and SBOM_LIB_STEM = libwolfprov. Consequences: (1) make sbom produces wolfprovider-1.2.1.* files, yet sbom.am sets sbomdir = $(docdir) which defaults to $(datarootdir)/doc/$(PACKAGE) = .../doc/wolfprov/, so install-sbom drops wolfprovider-* files into a wolfprov-named directory; (2) the SBOM component name / purl (wolfprovider) does not match the autoconf package identifier (wolfprov). The GitHub repo is wolfProvider, so the lowercased wolfprovider purl is defensible, but the split identity (wolfprovider in the SBOM, wolfprov for $(PACKAGE)/libwolfprov/docdir) is easy to trip over. The PR body's own Notes section originally stated the name should be wolfprov "throughout (matches AC_INIT and lib_LTLIBRARIES), not wolfprovider", so the two names are worth reconciling or documenting deliberately. This is not a build break (all paths resolve), just an identity inconsistency.
Fix: Confirm wolfprovider is the intended canonical SBOM/purl name and, if so, add a one-line comment noting it deliberately differs from $(PACKAGE)/libwolfprov (repo is github.com/wolfSSL/wolfProvider). Otherwise align SBOM_PKGNAME with $(PACKAGE) (wolfprov) so the output filenames match the doc install directory.
Summary
make sbom,make install-sbom, andmake uninstall-sbomtargets to wolfProvider's autotools build for EU CRA compliance evidence (CycloneDX 1.6 + SPDX 2.3 output)AC_CHECK_PROGchecks forpython3andpyspdxtoolsinconfigure.acUsage
WOLFSSL_DIRmust point to a wolfssl checkout containingscripts/gen-sbom(branchfeat/sbom-embedded, ormasteronce wolfSSL/wolfssl#10343 merges).Notes
wolfprovthroughout (matchesAC_INITandlib_LTLIBRARIES), notwolfprovideroptions.h; uses installed wolfssl'soptions.hvia$(WOLFSSL_INCLUDEDIR)/wolfssl/options.h.WOLFSSL_DIRdefaults to$(WOLFSSL_INSTALL_DIR)(set by--with-wolfssl=at configure time)libwolfprov.so.0.0.0(no-version-infoset) —--libpath uses this literal, not the package version1.1.1--with-wolfssl,WOLFSSL_INSTALL_DIRmay be malformed; passWOLFSSL_DIR=explicitly in that case